package com.csk.zsk.compents.entity;

import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.Table;

import org.codehaus.jackson.annotate.JsonIgnoreProperties;

import com.csk.zsk.commons.entity.IdEntity;

@Entity
@Table(name = "VIDEO_ITEM")
// 此annoation为了截断对象的循环引用.
@JsonIgnoreProperties({ "video" })
public class VideoItem extends IdEntity {

	private String nid;
	private String pid;
	private String tv_name;
	private String tv_url;
	private String tv_ver_id;
	private String video_big_pic;
	private Integer video_order;
	private Video video;

	public String getNid() {
		return nid;
	}

	public void setNid(String nid) {
		this.nid = nid;
	}

	public String getPid() {
		return pid;
	}

	public void setPid(String pid) {
		this.pid = pid;
	}

	public String getTv_name() {
		return tv_name;
	}

	public void setTv_name(String tv_name) {
		this.tv_name = tv_name;
	}

	public String getTv_url() {
		return tv_url;
	}

	public void setTv_url(String tv_url) {
		this.tv_url = tv_url;
	}

	public String getTv_ver_id() {
		return tv_ver_id;
	}

	public void setTv_ver_id(String tv_ver_id) {
		this.tv_ver_id = tv_ver_id;
	}

	public String getVideo_big_pic() {
		return video_big_pic;
	}

	public void setVideo_big_pic(String video_big_pic) {
		this.video_big_pic = video_big_pic;
	}

	public Integer getVideo_order() {
		return video_order;
	}

	public void setVideo_order(Integer video_order) {
		this.video_order = video_order;
	}

	@ManyToOne(fetch = FetchType.LAZY)
	@JoinColumn(name = "video_id")
	public Video getVideo() {
		return video;
	}

	public void setVideo(Video video) {
		this.video = video;
	}

}
